package ru.onlinestore.mobile.di

import org.koin.dsl.module
import ru.onlinestore.mobile.data.repository.ProductsRepositoryImpl
import ru.onlinestore.mobile.data.sources.ProductsRemoteSource
import ru.onlinestore.mobile.domain.repository.ProductsRepository
import ru.onlinestore.mobile.domain.usecase.GetProductListUseCase

val domainModule = module {

    single<ProductsRepository> {
        ProductsRepositoryImpl(
            remote = get<ProductsRemoteSource>()
        )
    }

    single {
        GetProductListUseCase(
            repository = get<ProductsRepository>()
        )
    }
}